import tableServiceAbstract from "@/core/table/tableService.interface";
import { $userGetList } from "@/api/user/user";
import { $getPlanList, $planEditAttr, $planSale, $planStopSale } from "@/api/productList/productList";
import { planList, planStopSale } from "@/api/productList/productList.interface";
export default class planListService implements tableServiceAbstract {
  getTable(params: planList): Promise<any> {
    return $getPlanList(params);
  }
  sale(params: planStopSale): Promise<any> {
    return $planSale(params);
  }
  stopSale(params: planStopSale): Promise<any> {
    return $planStopSale(params);
  }
  delete(params: any): Promise<any> {
    return new Promise((resolve) => {
      resolve({
        data: {
          code: 200,
          data: {},
          msg: 'success',
        }
      });
    })
  }
  add(params: any): Promise<any> {
    return new Promise((resolve) => {
      resolve({
        data: {
          code: 200,
          data: {},
          msg: 'success',
        }
      });
    })
  }
  edit(params: any): Promise<any> {
    return $planEditAttr(params);
  }
  detail(params: any): Promise<any> {
    return new Promise((resolve) => {
      resolve({
        data: {
          code: 200,
          data: {},
          msg: 'success',
        }
      });
    })
  }
}